package com.ztgf.order.models.service;

import com.baomidou.mybatisplus.service.IService;
//import com.ztgf.commodity.models.bo.OrderCommodityHighBO;
//import com.ztgf.commodity.models.vo.CommodityPriceVO;
//import com.ztgf.commodity.models.vo.OrderHighShopVo;
import com.ztgf.commodity.models.bo.OrderCommodityHighBO;
import com.ztgf.commodity.models.vo.CommodityPriceVO;
import com.ztgf.commodity.models.vo.OrderHighShopVo;
import com.ztgf.order.models.bo.OrderCommodityRelationSaveBO;
import com.ztgf.order.models.dto.OrderCommodityRelationDTO;
import com.ztgf.order.models.vo.OrderInfoVO;
import com.ztgf.shopping.models.dto.shop.ShopSysInvoiceDTO;

import java.math.BigDecimal;
import java.util.List;

/**
 * 订单商品表服务
 *
 * @author chenyu.wang
 * @Date 2020-06-03 15:55:40
 */
public interface IOrderCommodityRelationService extends IService<OrderCommodityRelationDTO> {
    boolean add(OrderCommodityRelationSaveBO saveBO);

    List<OrderHighShopVo> getOrderHighCommodity(OrderCommodityHighBO orderCommodityHighBO);

    List<CommodityPriceVO> getHighShop(OrderCommodityHighBO orderCommodityHighBO);

    /**
     * description: 修改订单普通商品价格
     * param: [id, price]
     * author: chenyu.wang
     * date: 2020-06-24
     * return: boolean
     */
    boolean updateOrderGoodsPrice(Long shopId, Long id, BigDecimal price);

    boolean updateOtherGoodsPrice(Long shopId, Long id, BigDecimal price);


    void restoreCommodityStock(Long orderId);

    /**
     * @return : java.util.List<com.ztgf.commodity.models.vo.CommodityPriceVO>
     * @Author :chenyu.wang
     * @Description : 获取商品浏览量排名，过滤下架商品
     * @Date : 2021.03.04 15:24
     * @Param : []
     **/
    List<CommodityPriceVO> getViewsGoods();

    /**
     * 同步技术服务费（卖家）
     * @Author :liyang
     * @return
     */
    List<ShopSysInvoiceDTO> synchronizationShopSysInvoiceSell();

    /**
     * 同步技术服务费（买家申请平台砍价成功）
     * @Author :liyang
     * @return
     */
    List<ShopSysInvoiceDTO> synchronizationShopSysInvoiceBuy();

    List<OrderCommodityRelationDTO> getByOrderId(Long orderId);

    List<String> addByOrderInfo(OrderInfoVO orderInfoVO);
}
